package com.wenhai.springbook;

import org.springframework.beans.factory.xml.XmlBeanFactory;
import org.springframework.core.io.ClassPathResource;
@SuppressWarnings("deprecation")
public class BeanFactoryTest {
    public static void main(String[] args) {
        XmlBeanFactory xmlBeanFactory = new XmlBeanFactory(new ClassPathResource("beanFactoryTest.xml"));
        MyTestBean myTestBean = xmlBeanFactory.getBean("myTestBean", MyTestBean.class);
        System.out.println(myTestBean.getMyBeanNameAware().getBeanName());
    }
}
